const Router = require('koa-router')
const { Success } = require('../../core/http-exception')
const { Auth } = require('../../core/middleware/auth')
const { Order } = require('../../models/order')
const router = new Router({
    prefix: '/v1/order',
})
router.get('/list', new Auth().m, async (ctx, next) => {
    const res = await Order.getList(ctx.auth.id)
    ctx.body = {
        code: 200,
        data: res,
    }
})
module.exports = router

